#include "commandprocess.h"
#include <QDebug>


CommandProcess::CommandProcess(QObject *parent)
    : QObject{parent}
{
    thread = new QThread();

    moveToThread(thread);
    thread->start();
}

CommandProcess::~CommandProcess()
{
    thread->quit();
    thread->wait();
}

void CommandProcess::receive_data(const QByteArray &data)
{
    // qDebug() << "func:" << __func__ << ",thread id:" << QThread::currentThreadId();
    qInfo() << "receive data,size:" << data.size();
    qDebug() << data.toHex(',').toUpper();
}
